import { createApp } from 'vue'
import { setupStore } from "@/store"
import { setupRouterGuard } from "@/router/guard"
import { router, setupRouter } from "@/router"
import { setupGlobDirectives } from '@/directives';
import { registerElement } from "@/plugins"
import './style/element-plus/index.scss'
import App from './App.vue'

const app = createApp(App)

// 注册element组件
registerElement(app)
// 配置pinia
setupStore(app)
// 配置路由
setupRouter(app)
// 配置路由守卫
setupRouterGuard(router)
// 注册全局指令
setupGlobDirectives(app);

app.mount('#app')
